import React, { Component } from 'react'
import { Button } from 'antd';
import './head.scss'
import { NavLink } from 'react-router-dom';
export default class head extends Component {
    loginHandle(){
        if(localStorage.token){
            alert('您已经登录了请勿重复登录')
            
        }
    }
    render() {
        return (
           <div className='head'>
           <span> 英雄联盟</span>
           <NavLink to='/login' exact> <Button type="primary" className='login' onClick={this.loginHandle.bind(this)}>登录/注册</Button></NavLink>
        </div>
        )
    }
}
